import com.itheima.Cat;
import com.itheima.Student;
import com.itheima.Teacher;

public class Task {

    public static void main(String[] args) throws Exception {
        // 创建Teacher对象
        Teacher t = new Teacher("播仔", 12000.34);
        // 创建Student对象
        Student s = new Student("小明", 18, '男', 1.78, "打篮球");
        // 创建Cat对象
        Cat c = new Cat("小花", 2);
        
        // 先清除现有文件
        ObjectFrame.clearObject();
        
        // 调用ObjectFrame的saveObject方法，保存对象
        ObjectFrame.saveObject(t);
        ObjectFrame.saveObject(s);
        ObjectFrame.saveObject(c);
    }

}